package com.atguigu.gulimail.feign;

import com.atguigu.common.utils.R;
import com.atguigu.gulimail.vo.SocialUser;
import com.atguigu.gulimail.vo.UserLoginVo;
import com.atguigu.gulimail.vo.UserRegisterVo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

@FeignClient("gulimail-member")
public interface MemberFeignService {
    @RequestMapping("/member/member/register")
    R register(@RequestBody UserRegisterVo registerVo);

    @PostMapping("/member/member/login")
    R login(@RequestBody UserLoginVo vo);

    @PostMapping("/member/member/oauth2/login")
    public R login(@RequestBody SocialUser vo) throws Exception;
}
